@include('home.public.header')
<!-- HEADING-BANNER START -->
<div class="heading-banner-area overlay-bg">
    <div class="container">
        <div class="row">
            <div class="col-md-12">
                <div class="heading-banner">
                    <div class="heading-banner-title">
                        <h2>博客</h2>
                    </div>
                    <div class="breadcumbs pb-15">
                        <ul>
                            <li><a href="/">Home</a></li>
                            <li>博客</li>
                        </ul>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<!-- HEADING-BANNER END -->
<!-- BLGO-AREA START -->

<div class="blog-area blog-2  pt-80 pb-80">
    <div class="container">
        <div class="blog">
            <div class="row">
                <div class="col-md-12">
                    <div class="product-option mb-30 clearfix">
                        <!-- Categories start -->
                        <div class="dropdown floatleft">
                            <button class="option-btn active" data-toggle="dropdown" >
                                Categories
                            </button>
                            <div class="dropdown-menu dropdown-width" >
                                <!-- Widget-Categories start -->
                                <aside class="widget widget-categories">
                                    <div class="widget-title">
                                        <h4>Categories</h4>
                                    </div>
                                    <div id="cat-treeview"  class="widget-info product-cat boxscrol2">
                                        <ul>
                                            <li><span>Chair</span>
                                                <ul>
                                                    <li><a href="#">T-Shirts</a></li>
                                                    <li><a href="#">Striped Shirts</a></li>
                                                    <li><a href="#">Half Shirts</a></li>
                                                    <li><a href="#">Formal Shirts</a></li>
                                                    <li><a href="#">Bilazers</a></li>
                                                </ul>
                                            </li>
                                            <li class="open"><span>Furniture</span>
                                                <ul>
                                                    <li><a href="#">Men Bag</a></li>
                                                    <li><a href="#">Shoes</a></li>
                                                    <li><a href="#">Watch</a></li>
                                                    <li><a href="#">T-shirt</a></li>
                                                    <li><a href="#">Shirt</a></li>
                                                </ul>
                                            </li>
                                            <li><span>Accessories</span>
                                                <ul>
                                                    <li><a href="#">T-Shirts</a></li>
                                                    <li><a href="#">Striped Shirts</a></li>
                                                    <li><a href="#">Half Shirts</a></li>
                                                    <li><a href="#">Formal Shirts</a></li>
                                                    <li><a href="#">Bilazers</a></li>
                                                </ul>
                                            </li>
                                            <li><span>Top Brands</span>
                                                <ul>
                                                    <li><a href="#">T-Shirts</a></li>
                                                    <li><a href="#">Striped Shirts</a></li>
                                                    <li><a href="#">Half Shirts</a></li>
                                                    <li><a href="#">Formal Shirts</a></li>
                                                    <li><a href="#">Bilazers</a></li>
                                                </ul>
                                            </li>
                                            <li><span>Jewelry</span>
                                                <ul>
                                                    <li><a href="#">T-Shirts</a></li>
                                                    <li><a href="#">Striped Shirts</a></li>
                                                    <li><a href="#">Half Shirts</a></li>
                                                    <li><a href="#">Formal Shirts</a></li>
                                                    <li><a href="#">Bilazers</a></li>
                                                </ul>
                                            </li>
                                        </ul>
                                    </div>
                                </aside>
                                <!-- Widget-categories end -->
                            </div>
                        </div>
                        <!-- Categories end -->
                        <!-- Price start -->
                        <div class="dropdown floatleft">
                            <button class="option-btn" data-toggle="dropdown" >
                                Price
                            </button>
                            <div class="dropdown-menu dropdown-width" >
                                <!-- Shop-Filter start -->
                                <aside class="widget shop-filter">
                                    <div class="widget-title">
                                        <h4>Price</h4>
                                    </div>
                                    <div class="widget-info">
                                        <div class="price_filter">
                                            <div class="price_slider_amount">
                                                <input type="submit"  value="You range :"/>
                                                <input type="text" id="amount" name="price"  placeholder="Add Your Price" />
                                            </div>
                                            <div id="slider-range"></div>
                                        </div>
                                    </div>
                                </aside>
                                <!-- Shop-Filter end -->
                            </div>
                        </div>
                        <!-- Price end -->
                        <!-- Color start -->
                        <div class="dropdown floatleft">
                            <button class="option-btn" data-toggle="dropdown" >
                                Color
                            </button>
                            <div class="dropdown-menu dropdown-width" >
                                <!-- Widget-Color start -->
                                <aside class="widget widget-color">
                                    <div class="widget-title">
                                        <h4>Color</h4>
                                    </div>
                                    <div class="widget-info color-filter clearfix">
                                        <ul>
                                            <li><a href="#"><span class="color color-1"></span>LightSalmon<span class="count">12</span></a></li>
                                            <li><a href="#"><span class="color color-2"></span>Dark Salmon<span class="count">20</span></a></li>
                                            <li><a href="#"><span class="color color-3"></span>Tomato<span class="count">59</span></a></li>
                                            <li class="active"><a href="#"><span class="color color-4"></span>Deep Sky Blue<span class="count">45</span></a></li>
                                            <li><a href="#"><span class="color color-5"></span>Electric Purple<span class="count">78</span></a></li>
                                            <li><a href="#"><span class="color color-6"></span>Atlantis<span class="count">10</span></a></li>
                                            <li><a href="#"><span class="color color-7"></span>Deep Lilac<span class="count">15</span></a></li>
                                        </ul>
                                    </div>
                                </aside>
                                <!-- Widget-Color end -->
                            </div>
                        </div>
                        <!-- Color end -->
                        <!-- Size start -->
                        <div class="dropdown floatleft">
                            <button class="option-btn" data-toggle="dropdown" >
                                Size
                            </button>
                            <div class="dropdown-menu dropdown-width" >
                                <!-- Widget-Size start -->
                                <aside class="widget widget-size">
                                    <div class="widget-title">
                                        <h4>Size</h4>
                                    </div>
                                    <div class="widget-info size-filter clearfix">
                                        <ul>
                                            <li><a href="#">M</a></li>
                                            <li class="active"><a href="#">S</a></li>
                                            <li><a href="#">L</a></li>
                                            <li><a href="#">SL</a></li>
                                            <li><a href="#">XL</a></li>
                                        </ul>
                                    </div>
                                </aside>
                                <!-- Widget-Size end -->
                            </div>
                        </div>
                        <!-- Size end -->
                        <div class="showing text-right hidden-xs">
                            <p class="mb-0">Showing 01-09 of 17 Results</p>
                        </div>
                    </div>
                </div>
            </div>
            <div class="row">
                <!-- Single-blog start -->
                <div id="row_list">
                {{--内容--}}
                </div>
{{--                @foreach($blog_list as $v)--}}
{{--                <div class="col-lg-4 col-md-4 col-sm-6 col-xs-12">--}}
{{--                    <div class="single-blog mb-30">--}}
{{--                        <div class="blog-photo">--}}
{{--                            <a href="#"><img src="/static/home/img/blog/3.jpg" alt="" /></a>--}}
{{--                            <div class="like-share text-center fix">--}}
{{--                                <a href="#"><i class="zmdi zmdi-favorite"></i><span>{{$v -> blog_like}}</span></a>--}}
{{--                                <a href="#"><i class="zmdi zmdi-comments"></i><span>{{$v -> blog_comments}}</span></a>--}}
{{--                                <a href="#"><i class="zmdi zmdi-share"></i><span>{{$v -> blog_share}}</span></a>--}}
{{--                            </div>--}}
{{--                        </div>--}}
{{--                        <div class="blog-info">--}}
{{--                            <div class="post-meta fix">--}}
{{--                                <div class="post-date floatleft"><span class="text-dark-red">{{date("d",$v -> blog_time)}}</span></div>--}}
{{--                                <div class="post-year floatleft">--}}
{{--                                    <p class="text-uppercase text-dark-red mb-0">{{date("Y-m",$v -> blog_time)}}</p>--}}
{{--                                    <h4 class="post-title"><a href="#" tabindex="0">{{$v -> blog_time}}</a></h4>--}}
{{--                                </div>--}}
{{--                            </div>--}}
{{--                            <p>{{$v -> blog_desc}}</p>--}}
{{--                            <a href="#" class="button-2 text-dark-red">Read more...</a>--}}
{{--                        </div>--}}
{{--                    </div>--}}
{{--                </div>--}}
{{--                @endforeach--}}
{{--                <!-- Single-blog end -->--}}
{{--            </div>--}}
{{--            <div class="row">--}}
{{--                <div class="col-md-12">--}}
{{--                    <!-- Pagination start -->--}}
{{--                    <div class="shop-pagination  text-center">--}}
{{--                        <div class="pagination">--}}
{{--                            {{$blog_list -> links('pagination::default')}}--}}
{{--                        </div>--}}
{{--                    </div>--}}
{{--                    <!-- Pagination end -->--}}
{{--                </div>--}}
{{--            </div>--}}
        </div>
    </div>
</div>
<!-- BLGO-AREA END -->
@include('home.public.footer2')
    <script>
        //阻止a默认跳转
        $(document).on('click',".num a",function () {
            //点击页码请求接口
            var page = $(this).html();
            getList(page);
            return false;
        });

        //点击上一页请求接口
        $(document).on("click","#preva",function () {
                var cur = $("#cur").html();
                var page = parseInt(cur) - 1 ;
                getList(page);
            return false;
        });

        //点击下一页请求接口
        $(document).on("click","#nexta",function () {
               var cur = $("#cur").html();
                var page = parseInt(cur) + 1;
                getList(page);
            return false;
        });

        function getList(page){
            $.ajax({
                type: 'get',
                url: '/blog_list',
                data: "page="+page,
                dataType: "html",
                success:function(res){
                    console.log(res);
                    $("#row_list").html(res);
                }
            })
        }
        getList(1);
    </script>
